class httpResponseSignal:
    '''
    设置response状态
    '''
    def __init__(self): # 初始化
        self.data = {}

    def getSuccess(self): # 成功返回
        self.data["status"] = "Success"
        self.data['code'] = 200
        self.data['error'] = 0
        self.data["data"] = {}
        return self.data

    def getFail(self): # 失败返回
        self.data['error'] = 1
        self.data['status'] = "False"
        self.data['code'] = 201
        return self.data

    def getErorr(self): # 错误返回
        self.data['error'] = 1
        self.data['status'] = "eroor"
        self.data['msg'] = '异常'
        self.data['code'] = 500
        return self.data